package com.spring.shops.dao;

import com.github.pagehelper.Page;
import com.spring.shops.model.dto.SysRoleDTO;
import com.spring.shops.model.entity.TzSysRole;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface TzSysRoleMapper {
    int deleteByPrimaryKey(Long roleId);

    int insert(TzSysRole record);

    int insertSelective(TzSysRole record);

    TzSysRole selectByPrimaryKey(Long roleId);

    int updateByPrimaryKeySelective(TzSysRole record);

    int updateByPrimaryKey(TzSysRole record);

    /**
     * 列出所有的角色
     * @return
     */
    @Select("select * from yami_shops.tz_sys_role")
    List<TzSysRole> selectAll();

    Page<TzSysRole> page(SysRoleDTO dto);
}